package com.example.importselectorstudy;

import com.example.importselectorstudy.service.impl.SayHelloServiceCN;
import com.example.importselectorstudy.service.impl.SayHelloServiceEn;
import org.springframework.context.annotation.ImportSelector;
import org.springframework.core.type.AnnotationMetadata;

public class SayHelloServiceImportSelector implements ImportSelector {
    @Override
    public String[] selectImports(AnnotationMetadata importingClassMetadata) {
        // 这里返回的类会被定义为bean
        return new String[] {SayHelloServiceCN.class.getCanonicalName(), SayHelloServiceEn.class.getCanonicalName()};
    }
}
